package servlet;

import java.io.IOException;
import java.io.PrintWriter;
import java.sql.ResultSet;
import java.util.List;

import javax.servlet.RequestDispatcher;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import vo.Information;
import dao.InformationDAO;

import JavaBeans.DbUtil;

public class RecycleSelect extends HttpServlet {

	
	public RecycleSelect() {
		super();
	}

	
	public void destroy() {
		super.destroy(); 
	
	}


	public void doGet(HttpServletRequest request, HttpServletResponse response)
			throws ServletException, IOException {
	request.setCharacterEncoding("UTF-8");
		
		String in_select_name =  new String(request.getParameter("in_select_name"));
		
		String user_name_server = (String)request.getSession().getAttribute("user_name_server");
		
		
		
		InformationDAO ido = new InformationDAO();
		List<Information> list = ido.select(user_name_server , in_select_name,1);
		
		RequestDispatcher rd;
		request.setAttribute("recycle_select", list);
		rd = request.getRequestDispatcher("/admin/recycle/recycle_select_return.jsp");
		rd.forward(request, response);
	}

	
	public void doPost(HttpServletRequest request, HttpServletResponse response)
			throws ServletException, IOException {

	}

	
	public void init() throws ServletException {
		
	}

}
